package com.punai.enterprisedatadisplay.constanta;

import com.punai.common.bos.KVBO;

import java.util.ArrayList;
import java.util.List;

public class OvershootSituationConstanta {

    public enum Tabs {
        DATA_KL("开累数据", "data_kl"),
        DATA_DN("当年数据", "data_dn"),
        DATA_DJ("当季数据", "data_dj"),
        DATA_DY("当月数据", "data_dy");

        private String code;

        private String name;

        Tabs(String name, String code) {
            this.name = name;
            this.code = code;
        }

        public String getCode() {
            return code;
        }

        public void setCode(String code) {
            this.code = code;
        }

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public static List<KVBO> getAllTab() {
            return new ArrayList<KVBO>() {{
                for (Tabs value : Tabs.values()) {
                    add(new KVBO(value.getCode(), value.getName()));
                }
            }};
        }

    }
}
